/**
 * Copyright &copy; 2012-2016 <a href="https://github.com/thinkgem/jeesite">JeeSite</a> All rights reserved.
 */
package com.thinkgem.jeesite.modules.source.entity.direction;

import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlTransient;

import org.hibernate.validator.constraints.Length;

import com.thinkgem.jeesite.common.persistence.DataEntity;

/**
 * 方向资源管理Entity
 * @author ZC
 * @version 2017-04-24
 */
public class EleSourceDirection extends DataEntity<EleSourceDirection> {
	
	private static final long serialVersionUID = 1L;
	private EleSourceDirectionGroup group;		// 电梯上下行信息组id 父类
	private String direction;		// 运行方向
	private String node;		// 状态单元
	
	public EleSourceDirection() {
		super();
	}

	public EleSourceDirection(String id){
		super(id);
	}

	public EleSourceDirection(EleSourceDirectionGroup group){
		this.group = group;
	}
	@XmlTransient
	@Length(min=0, max=100, message="电梯上下行信息组id长度必须介于 0 和 100 之间")
	public EleSourceDirectionGroup getGroup() {
		return group;
	}

	public void setGroup(EleSourceDirectionGroup group) {
		this.group = group;
	}
	@XmlTransient
	public String getDirection() {
		return direction;
	}

	public void setDirection(String direction) {
		this.direction = direction;
	}
	
	@XmlElement(name = "node")
	@Length(min=0, max=255, message="状态单元长度必须介于 0 和 255 之间")
	public String getNode() {
		return node;
	}

	public void setNode(String node) {
		this.node = node;
	}
	
}